﻿<%@ Page Language="C#" AutoEventWireup="true" CodeFile="SelectSend.aspx.cs" Inherits="Deparment_Filse_SelectSend" %>

<%@ Register Src="../../System/DbPageFlip.ascx" TagName="DbPageFlip" TagPrefix="uc1" %>

<html xmlns="http://www.w3.org/1999/xhtml">
<head id="Head1" runat="server">
    <title>选择发送人</title>
    <link href="../../styles/css.css" rel="stylesheet" type="text/css" />
</head>
<body>

    <script language="javascript" type="text/javascript">
    function SelelctCompany()
    {
		    var obj=new Object;
		    var count=0;
		    var a = document.getElementsByName('chk');
		    obj.Accountid="";obj.dwname="";
		     for(var i=0;i< a.length;i++)
		     {
		   
		      if(a[i].checked==true)
		      {
		       
		        obj.Accountid +=','+a[i].id;
		        obj.dwname +=','+a[i].value;
		     }
		    }
    	     self.opener.confirmvalue(obj);
		    window.close();
    }
    </script>

    <form id="form1" runat="server" >
        <div>
        <br />
        <br />
        <center>
    <table width="400" border="0" cellpadding="2" cellspacing="1">
                <tr>
                    <td align="right" style="height: 26px; width: 52px;">
                        发送人：</td>
                    <td style="height: 26px; width: 275px;">
                        <asp:TextBox ID="txtAttorneyName" runat="server" CssClass="input_text" Width="96px"></asp:TextBox>
                        <asp:Button ID="Button5" runat="server"  Text=""  CssClass="button_Query"/>
                        &nbsp; &nbsp;
                        <input id="Button1" type="button" value="确定选择" class="button_bg6" style="width: 64px" onclick=" SelelctCompany()" />
                        </td>
                        </tr>
        <tr>
            <td align="right" colspan="2" style="height: 26px">
                <asp:GridView ID="GridView1" runat="server" Width="100%" AutoGenerateColumns="False"　  CssClass='table_table' HeaderStyle-CssClass='table_title'>
                    <RowStyle Width="100%" />
                    <Columns>
                        <asp:BoundField DataField="Dwname" HeaderText="用户名" ItemStyle-HorizontalAlign="Center" />
                        <asp:TemplateField HeaderText="选择" ItemStyle-HorizontalAlign="Center">
                        　<ItemTemplate  >
                             <input id="<%# DataBinder.Eval(Container.DataItem,"accountid")%>" type="checkbox"  value="<%# DataBinder.Eval(Container.DataItem,"dwname")%>"  name="chk">选择
                        　</ItemTemplate>
                        </asp:TemplateField>
                    </Columns>
                </asp:GridView>
            </td>
        </tr>
            </table>
            </center>
        </div>
    </form>
</body>
</html>
